package patrol.mobile.com.mobilepatrol.adapter;

import android.content.Context;

import com.dl7.recycler.adapter.BaseQuickAdapter;
import com.dl7.recycler.adapter.BaseViewHolder;

import patrol.mobile.com.mobilepatrol.R;
import patrol.mobile.com.mobilepatrol.bean.EvaluationDetailBean;

/**
 * Created by K on 2018/9/14.
 * des: 我的考核
 */
public class MyEvaluationAdapter extends BaseQuickAdapter<EvaluationDetailBean> {
    public MyEvaluationAdapter(Context context) {
        super(context);
    }

    @Override
    protected int attachLayoutRes() {
        return R.layout.item_my_evaluation;
    }

    @Override
    protected void convert(BaseViewHolder holder, EvaluationDetailBean item) {
        holder.setText(R.id.tv_num, holder.getAdapterPosition() + 1 + "");
        holder.setText(R.id.tv_bei_kaohe, "被考核人：" + item.getCheckName());
        holder.setText(R.id.tv_kaohe, "考核人：" + item.getAssessor());
        holder.setText(R.id.tv_kou, "扣" + item.getDeductScore() + "分");
        holder.setText(R.id.tv_yu, "余" + item.getTotalScore() + "分");
        holder.setText(R.id.tv_replay, item.getAuditName());
        holder.setText(R.id.tv_time, item.getUpdateDate());
    }
}
